<div class="infoBlock">
<div class="infoBlockHeading"><span class="t">&nbsp;</span></div>
<div class="infoBlockContent">

<div class="infoBlockItem">
<div>
<img src="{$CONTEXT.STYLEIMAGE}contact_1.jpg" />
</div>

<div style="padding-left: 15px; ">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
  <tr>
    <td valign="top">
<div class="hbfmd" style="background-image: url({$CONTEXT.STYLEIMAGE}contact_2.jpg); background-position: top left; background-repeat: no-repeat; width: 354px; height: 450px;">
<form name="contactusform" id="contactusform" method="post">
<input type="hidden" name="action" value="addcontactus">
<table width="100%" border="0" cellspacing="0" cellpadding="1">
  <tr>
    <td colspan="2" height="5"></td>
  </tr>
  <tr>
    <td><label>Name:</label></td>
    <td><input type="text" name="field_name" value="" class="txta"></td>
  </tr>
  <tr>
    <td><label>Email:</label></td>
    <td><input type="text" name="field_email" value="" class="txta"></td>
  </tr>
  <tr>
    <td><label>Company:</label></td>
    <td><input type="text" name="field_company" value="" class="txta"></td>
  </tr>
  <tr>
    <td><label>Phone:</label></td>
    <td><input type="text" name="field_telephone" value="" class="txta"></td>
  </tr>
  <tr>
    <td><label>Address:</label></td>
    <td><input type="text" name="field_address" value="" class="txta"></td>
  </tr>
  <tr>
    <td></td>
    <td>
<table width="100%" border="0" cellspacing="0" cellpadding="1">
  <tr>
    <td><label>State:</label></td>
    <td><label>Zip:</label></td>
  </tr>
  <tr>
    <td><input type="text" name="field_state" value="" class="txtb"></td>
    <td><input type="text" name="field_postcode" value="" class="txtb"></td>
  </tr>
</table>
    </td>
  </tr>
  <tr>
    <td colspan="2"><label>Comments:</label><br />
    <textarea name="field_comment"></textarea>
    </td>
  </tr>
  <tr>
    <td colspan="2"><label>Picture:</label><br /><div class="pupd"><script type="text/javascript" language="javascript">puploadinit('item');</script></div></td>
  </tr>
  <tr>
    <td colspan="2" height="10">&nbsp;</td>
  </tr>
  <tr>
    <td><input type="image" src="{$CONTEXT.STYLEIMG}btn_submit.jpg" onclick="hbfm_submit();return false;" /></td>
    <td><input type="image" src="{$CONTEXT.STYLEIMG}btn_clear.jpg" onclick="hbfm_reset();return false;" /></td>
  </tr>
  <tr>
    <td colspan="2">Your information is safe with us!</td>
  </tr>
</table>
</form>
</div>    
    </td>
    <td valign="top">
<div style="background-image: url({$CONTEXT.STYLEIMAGE}contact_3.jpg); background-position: top left; background-repeat: no-repeat; width: 280px; height: 280px; padding: 10px;">

</div>
<div style="font-size: 13px; font-weight: bold;">
<p></p>
<p>&nbsp;</p>
<p></p>
</div>
    </td>
  </tr>
</table>
</div>
</div>

</div>
</div>

{literal}
<style type="text/css">
div.hbfmd {
	padding: 10px 10px 10px 10px;
	color: #b28750;
}
div.hbfmd table {

}
div.hbfmd label {
	color: #022d72;
	font-family: Verdana, Geneva, sans-serif;
	font-size: 11px;
}
div.hbfmd input.txta {
	width: 200px;
	height: 16px;
	margin-bottom: 3px;
}
div.hbfmd input.txtb {
	width: 70px;
	height: 16px;
}
div.hbfmd textarea {
	width: 300px;
}
div.hbfmd div.pupd {
	width: 300px;
}
</style>
<script type="text/javascript" language="javascript">
puploadrps = false;
function puploadcompletehandler(){
	var gc = puploadgc(puploadc);
	$E("PUPF").innerHTML = "";
	$E("PUPP").innerHTML = '<span class="right"><a href="javascript:void(0);" onclick="puploaddelete('+puploadc+')">X</a></span><span class="left">'+gc[3]+'</span>';
}
function puploaddeletehandler(){
	puploadc++;
	$E("PUPF").innerHTML = puploadf();
	$E("PUPH").innerHTML += puploadh();
	$E("PUPP").innerHTML = "";
}
//
function hbfm_submit(){
	var form = document.contactusform;
	if( form.field_name.value == "" ) {
		form.field_name.focus();
		return false;
	}
	if( form.field_email.value == "" ) {
		form.field_email.focus();
		return false;
	} else if( checkEmail(form.field_email.value) == false ) {
		form.field_email.select();
		form.field_email.focus();
		return false;
	}
	if( form.field_telephone.value == "" ) {
		form.field_telephone.focus();
		return false;
	}
	if( form.field_address.value == "" ) {
		form.field_address.focus();
		return false;
	}
	if( form.field_state.value == "" ) {
		form.field_state.focus();
		return false;
	}
	
	xc('ws_contactus', [xcgfm('contactusform')]);
}
function ws_contactus_cb(r) {
	if( r == 1 ) {
		alert("Thank you for your contact with us.\nWe will contact you for arranging your free estimate.");
		//var form = document.contactusform;
		//form.reset();
		//form.field_name.focus();
		hbfm_reset();
	} else {
		alert("ERROR");
	}
}
function hbfm_reset(){
	var form = document.contactusform;
	form.reset();
	form.field_name.focus();
	//
	puploadc++;
	$E("PUPF").innerHTML = puploadf();
	$E("PUPH").innerHTML += puploadh();
	$E("PUPP").innerHTML = "";
}
</script>
{/literal}
